package chapter09plus

/**
 *
 * @author cdhuangchao3
 * @date 2023/6/11 5:31 PM
 */
object Test01_Exception {
  def main(args: Array[String]): Unit = {
    try {
      val n = 10 / 0
    } catch {
      case e : ArithmeticException => {
        println("发送算术异常")
      }
      case e: Exception => {
        println("发送一般异常")
      }
    } finally {
      println("处理结束")
    }
  }
}
